import { request } from './request';

export async function getAllExperimentCourse() {
  return request('/api/experimentCourse', {
    method: 'GET',
  })
}

export async function appendExperimentCourse(data: any) {
  return request('/api/experimentCourse', {
    method: 'POST',
    data,
  })
}

export async function updateExperimentCourse(data: any) {
  return request(`/api/experimentCourse/${data?.ecId}`, {
    method: 'PUT',
    data,
  })
}

export async function destroyExperimentCourse(data: any) {
  return request(`/api/experimentCourse/${data?.ecId}`, {
    method: 'DELETE',
  })
}

export default {
  getAllExperimentCourse,
  appendExperimentCourse,
  updateExperimentCourse,
  destroyExperimentCourse,
};
